package com.powerunion.datacollection.transaction;

import com.powerunion.datacollection.config.ConfigUtil;


/**
 * <p>Title: </p>
 *
 * <p>Description: </p>
 *
 * <p>Copyright: Copyright (c) 2005</p>
 *
 * <p>Company: </p>
 *
 * @author not attributable
 * @version 1.0
 */
public class TransactionHelper {

        /**
         * 得到设置的事务对象
         * @return Transaction
         * @throws Exception
         */
    public static Transaction getTransaction()throws Exception{
        String className = ConfigUtil.getInstance().getParameter("transaction");
        return (Transaction)Class.forName(className).newInstance();
    }
}
